<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<script>
    function jsonp({url, cb}) {
        let script = document.createElement('script');
        return new Promise((resolve, reject) => {
            window[cb] = function (data) {
                resolve(data);
                document.removeChild(script)
            };
            script.src = url + cb;
            document.body.appendChild(script)
        })
    }

    let a = undefined
    jsonp({
        url: 'http://www.jsxwsx.com:9120/Zc_McWelcomeToDo.do?jasminessouser=4E0126135F86ADA6A35A9331DEFADBB00878787878133F011U1BFD8&callback=',
        cb: 'show'
    }).then((data) => {
        console.log(data);
    })


    function jsonps({url,cb}) {
        let script = document.createElement('script');
        return new Promise((resolve,reject)=>{
            window[cb] = function (data) {
                resolve(data);
                document.removeChild(script)
            };
            script.src=url+cb;
            document.body.appendChild(script)
        })
    }
</script>
</body>
</html>